bandwidth (link bandwidth) (the rate at which messages are transmitted over the network) and round-trip times (round-trip time) or RTT (the delay between the sending of a message and the response received to the other end). These two values determine what is called the Bandwidth Delay Product (BDP).Given the link bandwidth and RTT, you can calculate the value of the BDP, but what does that mean? The
kernel will also try to fill the entire buffer (and also need to keep the TCP Notification window open ). In this way, you can minimize the number of calls and achieve better overall performance.
The performance of TCP depends on several factors. The two most important factors are:Link bandwidth)(Packet transmission rate on the network) andRound-trip time)Or RTT (the delay between sending a message and receiving a response from the other end ). These two values are identifiedBandwidth Delay Pr
are the link bandwidth (link bandwidth) (the rate at which messages are transmitted over the network) and round-trip times (round-trip time) or RTT (the delay between the sending of a message and the response received to the other end). These two values determine what is called the Bandwidth Delay Product (BDP). Given the link bandwidth and RTT, you can calculate the value of the BDP, but what does that me
to minimize the number of times these calls are used. Fortunately, we can control this process.
Solution
When writing data to a socket, try to write all the data at a time, instead of performing multiple write operations. For read operations, it is best to pass in the maximum buffer that can be supported, because if there is not enough data, the kernel will also try to fill the entire buffer (and also need to keep the TCP notification window open ). In this way, you can minimize the number of
performing multiple write data operations. For a read operation, it is best to pass in the maximum buffer that can be supported, because if there is not enough data, the kernel will attempt to populate the entire buffer (in addition to keeping the TCP Advertisement window open). This way, you can minimize the number of calls and achieve better overall performance. Back to top of pageTip 3. To adjust the TCP window for Bandwidth Delay ProductThe performance of TCP depends on several factors. The
We are very familiar with UDP. Here we will introduce the UDT protocol. The two protocols are easy to confuse in terms of abbreviations. You must first distinguish them clearly. Next, let's compare and differentiate this part of content.
1. Introduction
With the increase of network bandwidth latency products (BDP), the TCP protocol is usually becoming inefficient. This is because its AIMDadditive increase multiplicative decrease) algorithm completely
operations, it is best to pass in the maximum buffer that can be supported, because if there is not enough data, the kernelIt will also try to fill the entire buffer (and also need to keep the TCP Notification window open ). In this way, you can minimize the number of calls and achieve better overall performance.
Tip 3. Adjust the TCP window for the bandwidth Delay Product
TCPThe performance depends on several factors. The two most important factors are the link bandwidth (linkbandwidth) (pack
congestion, this phase has a variety of algorithm implementations, usually keep the default can be, here is not one of the explanations, interested readers can check themselves.
...
How to adjust "rwnd" to a reasonable value
A lot of people have encountered the network transmission speed is too slow problem, for example, clearly is the hundred gigabit network, its maximum transmission of the theoretical value of the data also have to have a 10 trillion, but the actual situation is far apart,
and transmit queues by observing:
RX errors: Total number of packets received
RX dropped: Indicates that the packet has entered Ring Buffer , but due to insufficient memory for system reasons, it is discarded during the copy-to-memory process.
The RX overruns:overruns means that the packet is Ring Buffer discarded by the physical layer of the NIC, and that the CPU is not able to handle interrupts in a timely manner Ring Buffer , such as uneven distribution of interrupts.
Http://www.shl.com/TryATest/TakeaTest/default.aspx
Original address: http://bbs.yingjiesheng.com/thread-477-1-1.html thanks to the landlord to share ~
Now more and more foreign-funded enterprises (including investment banks, commercial banks, and the MT program of the industry) have included the online test or on-site test into the application process, many of the company's test problems come from an organization named SHL. I have participated in some investment banks (UBS, ML, HSBC Ib), hsbc
few months ago to achieve bbr similar things, but I can not imagine cubic so complicated things, the reason why Reno/cubic was used for more than 30 years, because people always think that is the right approach, No one seems to think that this is a problem.A new model based on the orthogonal base of {rtt,delivery rate} As one comes out, people seem to see the truth of the truth suddenly:The root of the problem is that the BBR congestion control model and the congestion control model prior to BB
the data structure is not well defined. And it's good for future maintenance.: Because you can see from the code that the data access is guaranteed to be volatile.Example: Exactly which volatile may be invalidIn the first few examples, it may be better to look at this example when you feel like you've already figured it out.struct hw_bd{..... volatile Char volatile buffer;}; struct hw_bd* bdp;......bdp
reading data on the Samba drive on the server.
4.3 adjust the TCP window for Bandwidth Delay Product
The performance of TCP depends on several factors. The most important factor is the link bandwidth (the speed at which packets are transmitted over the network) and the round-trip time (round-trip time) or RTT (the delay between sending a message and receiving a response from the other end ). These two values determine the content called BDP (Bandwidt
repetition of accepted dataTransfer. Reno Recovery period, there will be low throughput, long recovery time, do not have to re-send data, recovery after the end of the threshold is too low and so on some questionsSerious impact on performance.ConclusionThrough the above analysis we can see:It is a fundamental consequence of the absence of SACK that the sender have to choose betweenThe following strategies to recover from lost data:(1) retransmitting at the most one dropped packet per round-trip
.
Verify the provinceCities method cache first. After Eclipse starts tomcat to load the project, use JMeter to call the/bdp/city/province/cities. json interface:
The Eclipse console outputs the following:
This indicates that the request did not hit the cache, and the database query is used. JMeter requests again, and the Eclipse console outputs:
The following marked red part is the log of this request, which does not access the db log and cache hit
. You can observe the health of the receive and transmit queues through Ifconfig:
Rxerrors: Total number of packets received
RX dropped: Indicates that the packet has entered the Ringbuffer, but due to insufficient memory for system reasons, it is discarded during copying to memory.
The RX overruns:overruns means that the packet is discarded by the physical layer of the NIC without Ringbuffer, and the CPU is unable to handle the interrupt in a timely manner, which is one of
distribution of interrupts.When the number of dropped continues to increase, it is recommended to increase the Ringbuffer, using ethtool-g settings.
Inputpacket Queue (packet receive queues)When the rate at which packets are received is greater than the rate of the kernel TCP processing packets, the packets are buffered in the queue before the TCP layer. The length of the receive queue is set by the parameter Net.core.netdev_max_backlog.RecvbufferRecv buffer is a key parameter to adjust TC
maximum receive window is typically set with the BDP (the maximum read cache can be computed). The BDP is called the bandwidth delay product, which is the product of bandwidth and network delay, for example, if our bandwidth is 2Gbps and the delay is 10ms, then the bandwidth delay product BDP is 2G/8*0.01=2.5MB, So the maximum receive window can be set to 2.5MB
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.